#pragma once
#define max 1024
#define none_flush (1<<0)
#define line_flush (1<<1)
#define full_flush (1<<2)
typedef struct IO_FILE
{
    int fileno;
    int flag;//打开状态
    char outbuffer[max];
    int bufferlen;//buffer里面的有效元素
    int flush_method;
}myfile;
myfile* myfopen(const char* path,const char* mode);
void myfclose(myfile*);
int myfwrite(myfile*,const void* str,int len);
void myfflush(myfile*);
